home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1998 March
/
EnigmA AMIGA RUN 25 (1997)(G.R. Edizioni)(IT)[!][issue 1998-03].iso
/
recent2
/
stripcodes.lha
/
stripcodes
/
StripCodes.doc
Wrap
Text File
|
1998-01-14
|
5KB
|
156 lines
**************************** StripCodes V1.9 ***************************
Revision date: 16 Dec 1997
©1996-1997 Tim Jackson
At-A-Glance Guide to Changes since V1.8
---------------------------------------
- NEW FEATURE! Can now *replace* a particular code with another instead
of stripping it.
- No longer crashes if you break using Ctrl-C. Sorry about that bug.
- Giving the code to strip as an argument is now mandatory (before, code 0
was assumed if none was given).
- The progress indicator returns! :)
What is StripCodes?
-------------------
StripCodes is a simple little program which will strip any occurrences of a
given ASCII code from any file.
It will also replace any occurrences of a given ASCII code with another
given ASCII code.
What do I need to run it?
-------------------------
Any Amiga with WB2.04+.
Enough memory to load the file you wish to process in its entirety. If
anyone has any problems with this then I can easily add an option which
will allow files larger than the available memory to be processed.
What files should I have?
-------------------------
In this distribution, there should be the following files:
StripCodes
StripCodes.doc
StripCodes.doc.info
Copyright & Distribution
------------------------
StripCodes is FREEWARE. That means you can copy it and freely distribute
it (including uploading to a BBS/Aminet etc.), as long as:
- You don't charge anything for it (except a nominal charge for disk and
copying)
- You include all the files listed above in any distribution.
- You don't modify any files.
(For inclusion on compilation CDs or magazine coverdisks/cover CDs, contact
me. Any other queries, contact me. No permission is necessary for
inclusion on Aminet or Fred Fish CDs.)
The copyright of the program remains with me at all times.
Disclaimer
----------
You use this program entirely at your own risk. The author will accept no
responsibility whatsoever for any loss or damage caused by this program
including but not limited to loss of or damage to data.
Why write StripCodes?
---------------------
I needed a program simply to remove some rogue ASCII characters which a
program I was using was inserting into files. Initially StripCodes just
removed code 15s (the one I needed to remove) but I changed it to make it
more useful.
OK, what does it do exactly?
----------------------------
In it's usual form, it takes an input file, scans through it and writes it
to an output file, minus any occurrences of the code you wanted to remove.
In the new extended form, you can also add a code to *replace* the code
you have already specified.
How do I use it?
----------------
Simply call it from the CLI using:
StripCodes <input file> <output file> <code to act on> [optional code to
replace with]
Examples:
"StripCodes File1 File2 65"
Strip all occurrences of ASCII code 65 from File1 and save the result to
File2
"StripCodes File1 File2 10 13"
Replace all occurences of ASCII code 10 with code 13.
Future Improvements
-------------------
I can't think of anything useful I can add to this program, it's so
simple. But if you can, do let me know!
A further increase in speed would also be nice; I don't really have any
ideas for this at the moment, but I'll have a think.
Known Bugs
----------
Bugs?
Version History
---------------
V1.00 Original version.
V1.01 Read input file but had bug.
V1.02 Read input file correctly.
V1.03 Strips code 15s correctly.
V1.04 Now strips any codes and accepts output file.
V1.05 Now includes Control-C detection & better argument handling. Corrected
bug in argument handling.
V1.06 Added bad code checking & bug in output file handling removed.
V1.07 Now gives output information - FIRST PUBLIC RELEASE.
V1.7 Same as V1.07 but with Style Guide compliant version number :)
V1.8 Bit of an overhaul. No more null bytes on end of output files.
Progress indicator removed (for the time being).
~100% speed increase.
Minor bug in error handling corrected.
V1.9 No longer crashes on a Ctrl-C.
Added option to replace codes instead of stripping them. (Thanks
to Timo Ronkko for this suggestion)
Argument of code to strip now mandatory.
Progress indicator put back in (and no longer causes truncation of
output files!)
» Contact me! «
---------------
If you've found StripCodes useful, TELL ME ABOUT IT! The program is
freeware; there is nothing to be paid but I'd like to hear from you anyway.
Any bug reports or suggestions for improvement should also be sent to the
below e-mail address:
tim_jackson@bigfoot.com
I occasionally use IRC and when I do, my usual nick is Arcline. I tend to
hang around on IRCnet. A list of IRCnet servers can be found at:
http://www.irchelp.org/irchelp/networks/servers/ircnet.html